#include<iostream>
using namespace std;
class solution
{
private:
    int getge(int n)
    {
        return n % 10;
    }
    int getshi(int n)
    {
        return (n / 10) % 10;
    }
    int getbai(int n)
    {
        return (n / 100) % 10;
    }
    int getqian(int n)
    {
        return (n / 1000) % 10;
    }
public:
    float reverseFloat(float a)
    {
        a *= 10;
        return (float)(getge((int)a) * 1000 + (float)getshi((int)a) * 100 + (float)getbai((int)a) * 10 + (float)getqian((int)a)) / 1000;
    }
};

int main()
{
    float a; float b;
    cin >> a;
    solution s;
    cout << s.reverseFloat(a) << endl;
    return 0;
}